@mixin onepx($positions: top right bottom left, $border-color: #e6e6e6, $border-radius: 0) {
  &:after {
    content: '';
    pointer-events: none;
    position: absolute;
    width: 100%;
    height: 100%;
    left: 0;
    top: 0;
    border-radius: $border-radius;
    @each $position in $positions {
      border-#{$position}: 1px solid $border-color;
    }

    @media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 2dppx) {
      width: 200%;
      height: 200%;
      transform: scale(0.5);
      transform-origin: 0 0;
      border-radius: $border-radius * 2;
    }
  }
}
